import request from '@/utils/request'

// 查询聊天室列表
export function listChatRoom(query) {
  return request({
    url: '/system/tChatRoom/list',
    method: 'get',
    params: query
  })
}

// 查询聊天室详细
export function getChatRoom(id) {
  return request({
    url: '/system/tChatRoom/' + id,
    method: 'get'
  })
}

// 新增聊天室
export function addChatRoom(data) {
  return request({
    url: '/system/tChatRoom',
    method: 'post',
    data: data
  })
}

// 修改聊天室
export function updateChatRoom(data) {
  return request({
    url: '/system/tChatRoom',
    method: 'post',
    data: data
  })
}

// 删除聊天室
export function delChatRoom(ids) {
  return request({
    url: '/system/tChatRoom/' + ids,
    method: 'delete'
  })
}